<script setup lang="ts">
import DachuangCard from './DachuangProjectMarketCard2.vue';
import type { Project } from '../types/Project';

defineProps<{ projects: Project[], }>()
</script>

<template>
  <a-row :gutter="[0, 20]">
    <a-col
      v-for="(project, index) in projects" :key="index" :span="24"
    >
      <DachuangCard
        :app="{
          title: project.name,
          description: project.description,
          image: project.image ?? '', // 假设有图片字段，若无则为空
          tags: project.tags,
          likes: project.likeNum,
          views: project.lookNum,
          shares: project.shareNum,
          projectId: project.projectId,
        }"
      />
    </a-col>
  </a-row>
</template>

<style scoped>
</style>
